
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html style="height: 100%;">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<link rel="icon" href="${defaultUrls.cdn_url}favicon.ico" type="image/x-icon">
<link rel="shortcut icon" href="${defaultUrls.cdn_url}favicon.ico" type="image/x-icon">
<link rel="stylesheet" type="text/css" href="${defaultUrls.cdn_url}css/cssVelocityPage.css">
<style media="screen" type="text/css">
#container {
    background-image: url('${defaultUrls.cdn_url}icons/footer_clouds.png');  background-repeat: no-repeat;
    background-position: bottom right;
}
#mainContent {
padding: 10px 0 8px 0px;
}
input {
	font-size:20px;
	line-height:35px;
	width:100%;
	border: 1px solid rgb(169, 169, 169);
}
label {
	display:block;
	margin-top:10px;
}

h3 {
	padding-right:20px;
}

#body {
	letter-spacing: 0.5px;
}



</style>
<title>MyCollab is upgrading ...</title>
</head>
<body style="height: 100%; margin: 0; padding: 0; width: 100%;">
	<div id="container">
		<div id="header">
			<div class="header-mid">
					<table width="100%" height="100%" align="center" valign="center">
					   <tbody>
					  	 <tr>
					   		<td>
					  			<a href="https://www.mycollab.com">
					       			<img src="${defaultUrls.cdn_url}icons/logo_mycollab_2.png" alt="MyCollab">
						   		</a>
					   		</td>
					   		<td>
			        			<div style="text-align: right; font-size: 10px; vertical-align: middle;">
						            <a style="display: inline-block; vertical-align: middle;" href="${defaultUrls.facebook_url}" target="_blank">
						                <img src="${defaultUrls.cdn_url}icons/email/footer-facebook.png" height="20" width="20"/>
						            </a>
						            <a style="display: inline-block; vertical-align: middle;" href="${defaultUrls.google_url}" target="_blank">
						                <img src="${defaultUrls.cdn_url}icons/email/footer-google.png" height="20" width="20"/>
						            </a>
						            <a style="display: inline-block; vertical-align: middle;" href="${defaultUrls.twitter_url}" target="_blank">
						                <img src="${defaultUrls.cdn_url}icons/email/footer-twitter.png" height="20" width="20"/>
						            </a>
			        			</div>
			    			</td>
						</tr>
					   </tbody>
					</table>
			</div>
		</div>
		<div id="body">
			<div id="spacing""></div>
			<div id="mainBody">
				<div id="title">
					<h1 style="font-size:40px; margin-bottom:15px;">MyCollab is upgrading ...<h1>
				</div>
				<hr size="1" style="margin: 1px 0 20px 0; ">
				<div id="title" style="display:flex">
					<h3>The upgrade process may take several minutes. Please be patient ... <h3>
					<img src="${defaultUrls.cdn_url}icons/lazy-load-icon.gif" alt="Pulpit rock" style="height:18px;">
				</div>
				<div id="bottom">
				    <p>
						<a javascrip="void(0);" href="https://www.mycollab.com" style="text-decoration : none;
						float:left"><span>Copyright 2015 MyCollab. All rights reserved.</span></a>

						<div style="text-align:right;">
						<a javascrip="void(0);" href="https://www.mycollab.com/terms" style="text-decoration : none;"><span>Terms of Service</span></a> &nbsp;&nbsp;&nbsp;
						<span>|</span>
						&nbsp;&nbsp;&nbsp;<a javascrip="void(0);" href="https://www.mycollab.com/privacy" style="text-decoration : none;"><span >Privacy Policy</span></a>
						</div>
					</p>
				</div>
			</div>
		</div>
	</div>
	<input type="hidden" id="postUrl" value=$!postUrl>
</body>
<script src="/assets/js/jquery-2.1.4.min.js"></script>
<script type="text/javascript">
    $(document).ready(function () {
        checkUpgradeReady();
    });
    function checkUpgradeReady(){
      var urlPost = "/it/upgrade_status";
      $.ajax({type: 'GET', url: urlPost,
        success: function(data) {
          if(data!=null){
            if(data.length > 0) {
              setTimeout(checkUpgradeReady, 5000);
            } else {
              alert("MyCollab is upgraded successfully. Redirect to the app?");
              window.location.assign("/");
            }
          }
        },
        error: function(XMLHttpRequest, textStatus, errorThrown) {
          setTimeout(checkUpgradeReady, 5000);
        }
      });

    }
</script>
</html>